<?php
/**
 * Author: Dcr
 * Date: 2019/7/17
 * Time: 16:01
 */
namespace app\home\controller;
defined('IN_DCR') or exit('No permission resources.');
use dcr\Controller;
use dcr\Model;
class IndexController extends Controller
{
    function index(){
        $model = new Model();
        $list = $model->db->fetchall('SELECT * FROM account');
        pr($list);
        $list = $model->db->fetch('SELECT * FROM news ORDER BY id DESC LIMIT 1');
        pr($list);
        $count = $model->db->count('my_admin','id');
        vr($count);
        //调用模板
        include $this->show();
    }
    function pdo(){

    }
    function userInfo(){
        echo __METHOD__;
    }
}